package com.qige.homework;

public class homework2 {
    public static void main(String[] args) {
        Person[] arr = new Person[2];
        arr[0] = new Woman();
        arr[1] = new Man();
        for (int i = 0; i < arr.length; i++) {
            arr[i].peek();
        }
    }
}
abstract class Person {
    public abstract void peek() ;
}
class Woman extends Person {
    public void peek() {
        System.out.println("坐着尿");
    }
}
class Man extends Person {
    public void peek() {
        System.out.println("站着尿");
    }
}